package com.dwms.feign;


import com.dwms.entity.Result;
import com.dwms.entity.common.CommonMessage;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * MQ服务
 *
 * @author WH
 */
@FeignClient(value = "mq-server")
public interface MqFeignClient {


    /**
     * 发送无序消息
     */
    @PostMapping("/mq/api/sendMsg")
    Result sendMsg(@RequestBody CommonMessage commonMessage);

    /**
     * 发送有序消息
     */
    @PostMapping("/mq/api/sendOrderMsg")
    Result sendOrderMsg(@RequestBody CommonMessage commonMessage);

    /**
     * 发送定时/延时消息
     */
    @PostMapping("/mq/api/sendDelayMsg")
    Result sendDelayMessage(@RequestBody CommonMessage commonMessage);
}
